import axios from 'axios';

export {  } from './public';

export async function GET(url, params = {}) {
    let res = {};
    try {
        res = await axios.get(url, { params });
    } catch (error) {
        throw new Error(error);
    }
    return res.data;
}

export async function POST(url, data = {}) {
    let res = {};
    try {
        res = await axios.posy(url, data);
    } catch (error) {
        throw new Error(error);
    }
    return res.data;
}